render: Remove gtk_render_slider
authorTimm Bäder <mail@baedert.org>
Sat, 7 Jul 2018 12:36:59 +0000 (14:36 +0200)
committerTimm Bäder <mail@baedert.org>
Sun, 8 Jul 2018 07:41:15 +0000 (09:41 +0200)
The only thing it was doing is render background and frame, which you
get from using a widget for your slider anyway.

docs/reference/gtk/gtk4-sections.txt
gtk/gtkrender.c

index 3ed1105e3399ed6e62c8ee86a1e2b487fc993ddb..489c8382701176f9a112078dd8b4022171a2e917 100644 (file)
@@ -4912,7 +4912,6 @@ gtk_render_handle
 gtk_render_layout
 gtk_render_line
 gtk_render_option
-gtk_render_slider
 gtk_render_activity
 gtk_render_icon
 gtk_render_insertion_cursor
index 12c0fa2775f512d2f17da37b59db97fb6e018d1d..3c90bb03d2d5d0f13577660a3fdd270e2a1a3b69 100644 (file)
@@ -550,63 +550,6 @@ gtk_render_line (GtkStyleContext *context,
   gtk_do_render_line (context, cr, x0, y0, x1, y1);
 }
 
-static void
-gtk_do_render_slider (GtkStyleContext *context,
-                      cairo_t         *cr,
-                      gdouble          x,
-                      gdouble          y,
-                      gdouble          width,
-                      gdouble          height,
-                      GtkOrientation   orientation)
-{
-  GtkCssStyle *style;
-
-  style = gtk_style_context_lookup_style (context);
-
-  gtk_css_style_render_background (style,
-                                   cr,
-                                   x, y, width, height);
-  gtk_css_style_render_border (style,
-                               cr,
-                               x, y, width, height);
-}
-
-/**
- * gtk_render_slider:
- * @context: a #GtkStyleContext
- * @cr: a #cairo_t
- * @x: X origin of the rectangle
- * @y: Y origin of the rectangle
- * @width: rectangle width
- * @height: rectangle height
- * @orientation: orientation of the slider
- *
- * Renders a slider (as in #GtkScale) in the rectangle defined by @x, @y,
- * @width, @height. @orientation defines whether the slider is vertical
- * or horizontal.
- *
- * Typical slider rendering:
- *
- * ![](sliders.png)
- **/
-void
-gtk_render_slider (GtkStyleContext *context,
-                   cairo_t         *cr,
-                   gdouble          x,
-                   gdouble          y,
-                   gdouble          width,
-                   gdouble          height,
-                   GtkOrientation   orientation)
-{
-  g_return_if_fail (GTK_IS_STYLE_CONTEXT (context));
-  g_return_if_fail (cr != NULL);
-
-  if (width <= 0 || height <= 0)
-    return;
-
-  gtk_do_render_slider (context, cr, x, y, width, height, orientation);
-}
-
 static void
 gtk_css_style_render_frame_gap (GtkCssStyle     *style,
                                 cairo_t         *cr,